package com.hxc.mapper;

import com.hxc.entity.Student;
import com.hxc.entity.StudentQueryParam;
import org.apache.ibatis.annotations.*;

import java.util.List;

@Mapper
public interface StudentMapper {
    @Select("select * from student where clazz_id = #{id}")
    List<Student> getStudentByClazzId(int id);

    List<Student> getStudentPage(StudentQueryParam param);

    @Select("select * from student where id = #{id}")
    Student getStudentById(Integer id);

    void addStudent(Student student);

    void updateStudent(Student student);

    void deleteStudent(Integer[] ids);

    void updateViolation(Integer id, Integer score);
}
